<%-- 
    Document   : paziente
    Created on : 7-dic-2011, 13.08.07
    Author     : sestari
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>

<%@taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
<%@taglib prefix="rich" uri="http://richfaces.org/rich"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">


<html>
    <f:view>
        <head>

            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
            <link rel="stylesheet" type="text/css" href="../style_generale.css" />
            <f:loadBundle basename="message.message" var="msg"/>        
            <title> <h:outputText value="#{msg.paginaanagrafica}"/> </title>

        </head>
        <body>


            <h:outputText value="#{msg.anagraficaPaziente}"/>
            <br>
            <h:form>
                <h:dataTable value="#{paziente.anagrafica}" var="anag"
                             style="overflow:auto; width:100%; height:50px"                             
                             styleClass="orders" headerClass="ordersHeader" columnClasses="evenColumn,oddColumn"> 
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.nome}"/>
                        </f:facet>
                        <h:outputText value="#{anag.nome}"/> 
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.cognome}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.cognome}"/> 
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.data_nascita}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.data_nascita}"> 
                            <f:convertDateTime type="date" dateStyle="short"/>
                        </h:outputText> 
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.sesso}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.sesso}"/> 
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.luogo_nascita}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.luogo_nascita}"/> 
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.indirizzo}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.indirizzo}"/> 
                    </h:column> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.cap}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.cap}"/> 
                    </h:column> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.e_mail}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.e_mail}"/> 
                    </h:column> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.cellulare}"/> 
                        </f:facet>
                        <h:outputText value="#{anag.cellulare}"/> 
                    </h:column> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.foto}"/> 
                        </f:facet>                              
                        <h:graphicImage value="#{anag.foto}" width="50"/>                                                
                    </h:column>
                </h:dataTable> 



                <h:outputText value="#{msg.id_capo_villaggio}"/>


                <h:dataTable value="#{paziente.capo}" var="cvil"
                             style="overflow:auto; width:100%; height:50px"
                             styleClass="orders" headerClass="ordersHeader" columnClasses="evenColumn,oddColumn"> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.nome}"/> 
                        </f:facet>                              
                        <h:outputText value="#{cvil.nome}" />                                                
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.cognome}"/> 
                        </f:facet>                              
                        <h:outputText value="#{cvil.cognome}"/>                                                
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.foto}"/> 
                        </f:facet>                              
                        <h:graphicImage value="#{cvil.foto}" width="50"/>                                                
                    </h:column>

                </h:dataTable> 

                <h:outputText value="#{msg.id_padre}"/>



                <h:dataTable value="#{paziente.padre}" var="pad"
                             style="overflow:auto; width:100%; height:50px"
                             styleClass="orders" headerClass="ordersHeader" columnClasses="evenColumn,oddColumn"> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.nome}"/> 
                        </f:facet>                              
                        <h:outputText value="#{pad.nome}"/>                                                
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.cognome}"/> 
                        </f:facet>                              
                        <h:outputText value="#{pad.cognome}"/>                                                
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.foto}"/> 
                        </f:facet>                              
                        <h:graphicImage value="#{pad.foto}" width="50"/>                                                
                    </h:column>

                </h:dataTable> 



                <h:outputText value="#{msg.id_madre}"/>
                <h:dataTable value="#{paziente.madre}" var="mad"
                             style="overflow:auto; width:100%; height:50px"
                             styleClass="orders" headerClass="ordersHeader" columnClasses="evenColumn,oddColumn"> 

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.nome}"/> 
                        </f:facet>                              
                        <h:outputText value="#{mad.nome}"/>                                                
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.cognome}"/> 
                        </f:facet>                              
                        <h:outputText value="#{mad.cognome}" />                                                
                    </h:column>

                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="#{msg.foto}"/> 
                        </f:facet>                              
                        <h:graphicImage value="#{mad.foto}" width="50"/>                                                
                    </h:column>

                </h:dataTable> 
                
                
                <rich:gmap mapType="G_NORMAL_MAP" lat="#{paziente.getLat()}" lng="#{paziente.getLng()}"  zoom="14" gmapKey="AIzaSyCLGKsF0cAn2iF5mnaMwcQIzdrhUdaQ4-Q"/>


           


            </h:form>

            <h:form>
                <h:commandButton value="#{msg.back}" action="back" styleClass="button"/>                
            </h:form>
            <br>
            <br>
            <br>            
            <%@ include file="/lingua/lingua.jsp" %>



        </body>
    </f:view>
</html>




